<template>
  <div class="one">
          <div class="onetop">
            <img src="@/assets/logo.png" alt="" class="oneimage" />
            <div class="text">
              <div class="onetitle">{{ item.name }}</div>
              <dir class="onedescribe">
                美味的曲奇加上芝士的碰撞产生奇妙的火花
              </dir>
            </div>
          </div>
          <div class="onebottom">
            <div class="price">￥{{ item.price }}</div>
            <slot name="method"></slot>
          </div>
  </div>
    
</template>

<script>
export default {
    props:{
        item:{type:Object,default:{}}
    }
}
</script>

<style scoped>
.one {
  width: 30%;
  background-color: rgb(255, 255, 255);
  border-radius: 15px;
  padding: 10px;
  margin: 0px 25px 25px 0;
  display: inline-block;
}
.onetop {
  width: 100%;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
}
.oneimage {
  height: 100px;
  width: 100px;
}
.text {
  width: 70%;
  margin-left: 10px;
}
.onetitle {
  color: rgb(44, 44, 44);
  font-size: 20px;
  font-weight: 800;
}
.onedescribe {
  color: rgb(151, 151, 151);
  font-size: 16px;
  font-weight: 800;
  padding: 0;
}
.onebottom {
  width: 100%;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
}
.price {
  color: rgb(44, 44, 44);
  font-size: 20px;
  font-weight: 800;
}
</style>